﻿/*
   RxInputManager
   Copyright 2011 Jordan Neumeyer

   Licensed under the Apache License, Version 2.0 (the "License");
   you may not use this file except in compliance with the License.
   You may obtain a copy of the License at

       http://www.apache.org/licenses/LICENSE-2.0

   Unless required by applicable law or agreed to in writing, software
   distributed under the License is distributed on an "AS IS" BASIS,
   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
   See the License for the specific language governing permissions and
   limitations under the License.
   
   File: NoGamePad.cs 
 */
using System;
using System.Reactive.Linq;
using Microsoft.Xna.Framework.Input;
using RxInputManager.Interfaces;

namespace RxInputManager.Devices
{
    public class NoGamePad : RxDevice<GamePadState>, IRxGamePad
    {
        public NoGamePad()
            : base()
        {
            //baseEvent = null;
        }

        public override bool IsAttached
        {
            get { return false; }
        }

        protected override GamePadState CurrentState
        {
            get { return new GamePadState(); }
        }

        public IObservable<GamePadState> ButtonPressed(Buttons button)
        {
            return Observable.Never<GamePadState>();
        }

        public IObservable<GamePadState> ButtonPressedOnce(Buttons button)
        {
            return Observable.Never<GamePadState>();
        }

        public IObservable<GamePadState> ButtonReleased(Buttons button)
        {
            return Observable.Never<GamePadState>();
        }

        public IObservable<GamePadState> ButtonHeld(Buttons button, int delayTime = RxInputManager.Constants.DelayTime)
        {
            return Observable.Never<GamePadState>();
        }


        public IObservable<bool> ControllerActivated(Buttons? key = null)
        {
            return Observable.Never<bool>();
        }


        public IObservable<GamePadState> ButtonsPressed(System.Collections.Generic.HashSet<Buttons> buttons)
        {
            return Observable.Never<GamePadState>();
        }

        public IObservable<GamePadState> ButtonsPressedOnce(System.Collections.Generic.HashSet<Buttons> buttons)
        {
           return Observable.Never<GamePadState>();
        }

        public IObservable<GamePadState> ButtonsHeld(System.Collections.Generic.HashSet<Buttons> buttons, int delayTime = RxInputManager.Constants.DelayTime)
        {
            return Observable.Never<GamePadState>();
        }


        public IObservable<GamePadState> Sticks(Buttons button, int threadHold)
        {
            return Observable.Never<GamePadState>();
        }

        public IObservable<GamePadState> RawState
        {
            get
            {
                return Observable.Never<GamePadState>();
            }
        }

        public void SetPlayerID(Microsoft.Xna.Framework.PlayerIndex playerID)
        {
            
        }
    }
}
